{% load i18n %}{% spaceless %}
<table class="table table-striped table-condensed table-hover">
    <thead>
        <tr>
            <th width="45%">{% trans "Summary" %}</th>
            <th width="25%">{% trans "Referee" %}</th>
            <th width="30%">{% trans "Current State" %}</th>
        </tr>
    </thead>
    <tbody>
    {% verbatim %}
        <tr ng-repeat="obj in data">
            <td>
                <span ng-if="obj.completed == false" class="glyphicon glyphicon-unchecked"></span>
                <span ng-if="obj.completed == true" class="glyphicon glyphicon-check"></span>
                <span>&nbsp;<a bmf-detail="{{ obj.pk }}" href="#">{{ obj.summary }}</a></span>
            </td>
            <td>
                {{ obj.referee_name || "---" }}
                <div ng-if="obj.project != 'None'">
                    <small><!--a href="#"--!>{{ obj.project_name }}<!--/a--></small>
                </div>
            </td>
            <td class="text-center">
                <span ng-if="obj.completed == true" class="text-muted">
                    {% endverbatim %}{% trans "completed" %}{% verbatim %}
                </span>
                <div ng-if="obj.completed == false" class="progress" style="margin:0;">
                    <div ng-if="obj.state_summary.done > 0." class="progress-bar progress-bar-success" style="width: {{ obj.state_summary.done }}%"></div>
                    <div ng-if="obj.state_summary.todo > 0." class="progress-bar progress-bar-warning" style="width: {{ obj.state_summary.todo }}%"></div>
                    <div ng-if="obj.state_summary.review > 0." class="progress-bar progress-bar-info" style="width: {{ obj.state_summary.review }}%"></div>
                    <div ng-if="obj.state_summary.hold > 0." class="progress-bar progress-bar-danger" style="width: {{ obj.state_summary.hold }}%"></div>
                </div>
            </td>
        </tr>
    {% endverbatim %}
    </tbody>
    {% block related_tfoot %}
    <tfoot ng-if="scopename=='related'">
      <tr>
        <td colspan="3" class="text-right">
          <a class="btn btn-xs bmf-edit btn-success" bmf-form="create" href="{% url "djangobmf:moduleapi_djangobmf_task_goal:create" "default" %}">
            <span class="glyphicon glyphicon-plus"></span>
          </a>
        </td>
      </tr>
    </tfoot>
    {% endblock %}
</table>
{% comment %}
TODO: Try to reenable grouping by projects with angular
{% regroup object_list by project as projects %}
{% endcomment %}
{% endspaceless %}
